package com.xlh.service.conclude;

import com.xlh.dto.conclude.BusiFullMarkDTO;
import com.xlh.vo.conclude.ConcludeScoreCheckVO;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

/**
 * @author cfz
 */
public interface ConcludeScoreService {

    /**
     * 下载模板
     * @param concludeId
     */
    void downLoadTemplate(Long concludeId, HttpServletRequest request, HttpServletResponse response);


    /**
     * 下载考核分项模板
     * @param concludeId
     */
    void downTemplateSub(Long concludeId, Long checkId,
                         HttpServletRequest request, HttpServletResponse response);


    /**
     * 考核分项成绩导入
     * @param checkId
     * @param file
     * @param headerIndex
     * @return
     */
    Map<String, Object> updateScoreSub(Long checkId, MultipartFile file, int headerIndex);

    /**
     * 整体成绩导入
     * @param concludeId
     * @param file
     */
    Map<String, Object> updateScoreEntirety(Long concludeId, MultipartFile file);


    /**
     * 达成度统计表展示
     * @param concludeId
     * @return
     */
    List<ConcludeScoreCheckVO> statistics(Long concludeId);


    /**
     *  整体数据下载
     * @param concludeIdLong
     * @param request
     * @param response
     */
    void entiretyDownload(Long concludeIdLong, HttpServletRequest request, HttpServletResponse response);


    /**
     * 从系统中更新分数
     * @param courseId 课程ID
     * @param studentId 学生ID
     * @param busiType 业务类型
     * @param score 学生分数
     */
    void updateScoreFromSys(Long courseId, Long studentId, String busiType, BigDecimal score, BigDecimal fullMark);




    void saveToConclude(BusiFullMarkDTO scoreDTO);


    /**
     * 保存到工程认证
     * @param lists
     * @param courseId
     */
    void saveToConclude(List<BusiFullMarkDTO> lists, Long courseId, String busiType);
}
